docusaurus 安装
1.安装nodejs
说明
docusaurus2.x版本需要16.14+版本的nodejs
1.1 下载二进制包
export NODEJS_VERSION=16.20.2
wget https://nodejs.org/dist/v${NODEJS_VERSION}/node-v${NODEJS_VERSION}-linux-x64.tar.xz
1.2 解压缩
tar xf node-v${NODEJS_VERSION}-linux-x64.tar.xz -C /usr/local/
mv /usr/local/node-v${NODEJS_VERSION}-linux-x64 /usr/local/node-v${NODEJS_VERSION}
1.3 导出命名环境变量
echo "export PATH=$PATH:/usr/local/node-v${NODEJS_VERSION}/bin" > /etc/profile.d/nodejs.sh
source /etc/profile